from selenium import webdriver
from selenium.webdriver.common.by import By
from time import sleep

chen_jian_guan_li = webdriver.Chrome()
chen_jian_guan_li.maximize_window()

chen_jian_guan_li.implicitly_wait(5)

chen_jian_guan_li.get('https://www.whucgcmc.cn:31443/login.html')

chen_jian_guan_li.find_element(By.CSS_SELECTOR, '[placeholder="输入手机号"]').send_keys('13421329027')
chen_jian_guan_li.find_element(By.CSS_SELECTOR, '[placeholder="验证码"]').send_keys('21789')
chen_jian_guan_li.find_element(By.CSS_SELECTOR, '.ivu-form-item-content > [type="button"]>span').click()
chen_jian_guan_li.get('https://www.whucgcmc.cn:31443/cockpit/')

sleep(10)
chen_jian_guan_li.find_element(By.CSS_SELECTOR, '.title_center div:nth-of-type(5)').click()
# sleep(30)

monitoring = chen_jian_guan_li.find_elements(By.XPATH, '//*[@class = list_item__lay]')
for monitoring_text in monitoring:
    qu = monitoring_text.find_element(By.CSS_SELECTOR, '.icon_text').text
    print(qu)
